home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / std / c++ / 201 / text0000.txt < prev   
Encoding:
Text File  |  1996-08-06  |  1.1 KB  |  27 lines

  1. >>>>> Jason Merrill <jason@cygnus.com> writes:
  2. >>>>> Eugene Radchenko <eugene@qsar.chem.msu.su> writes:
  3.  
  4. >> 3) Clause [temp.arg.explicit] verses 2-3 requires that for explicit arg in
  5. >> member template to be present it must be qualified by 'template' keyword,
  6. >> e.g.
  7. >> X *p; p->template alloc<200>();
  8. >> But to use operator -> we need X class definition anyway - so we know that
  9. >> alloc() is a template.
  10.  
  11. > It is needed in some situations where we do not have the X class definition
  12. > -- in template definitions, like with typename.
  13.  
  14. But then, the rule in the WP applies regardless of whether we know about X.
  15. I conclude that the idea was to allow the parser to do its work without
  16. peeking into classes to find names used after . or ->; another rule along
  17. the same lines requires that a scope used after . or -> have the same
  18. meaning in the ambient scope and the scope of the object specified.
  19.  
  20. Jason
  21.  
  22.  
  23. [ comp.std.c++ is moderated.  Submission address: std-c++@ncar.ucar.edu.
  24.   Contact address: std-c++-request@ncar.ucar.edu.  The moderation policy
  25.   is summarized in http://dogbert.lbl.gov/~matt/std-c++/policy.html. ]
  26.  
  27.